package cn.edu.imau.zy.exam.service.impl;

import java.util.List;

import cn.edu.imau.zy.common.core.entity.examination.EPaperInfo;
import cn.edu.imau.zy.exam.mapper.EPaperInfoMapper;
import cn.edu.imau.zy.exam.service.IEPaperInfoService;
import org.springframework.stereotype.Service;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.core.toolkit.Wrappers;
import org.apache.commons.lang3.StringUtils;
import org.springframework.stereotype.Service;

import cn.edu.imau.zy.common.core.text.Convert;

/**
 * 试卷信息Service业务层处理
 * 
 * @author xsc
 * @date 2021-12-04
 */
@Service
public class EPaperInfoServiceImpl extends ServiceImpl<EPaperInfoMapper, EPaperInfo> implements IEPaperInfoService
{
    @Override
    public List<EPaperInfo> queryList(EPaperInfo ePaperInfo) {
        LambdaQueryWrapper<EPaperInfo> lqw = Wrappers.lambdaQuery();
                                                                                                    if (StringUtils.isNotBlank(ePaperInfo.getName())){
                        lqw.like(EPaperInfo::getName ,ePaperInfo.getName());
                    }
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    return this.list(lqw);
    }
}
